home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1999 March / EnigmA AMIGA RUN 35 (1999)(G.R. Edizioni)(IT)[!][issue 1999-03].iso / earcd / devel / vbcc-src / machines / alpha / machine.h < prev    next >
C/C++ Source or Header  |  1999-01-01  |  2KB  |  64 lines

  1. /*  Example of a code-generator for a DEC Alpha                     */
  2.  
  3. #include "dt.h"
  4.  
  5. /*  This struct can be used to implement machine-specific           */
  6. /*  addressing-modes.                                               */
  7. /*  Not used in this code-generrator.                               */
  8. struct AddressingMode{
  9.   int flags;
  10.   int base;
  11.   int align;
  12.   long offset;
  13. };
  14.  
  15. /*  The number of registers of the target machine.                  */
  16. #define MAXR 64
  17.  
  18. /*  Number of commandline-options the code-generator accepts.       */
  19. #define MAXGF 10
  20.  
  21. /*  If this is set to zero vbcc will not generate ICs where the     */
  22. /*  target operand is the same as the 2nd source operand.           */
  23. /*  This can sometimes simplify the code-generator, but usually     */
  24. /*  the code is better if the code-generator allows it.             */
  25. #define USEQ2ASZ 1
  26.  
  27. /*  This specifies the smallest integer type that can be added to a */
  28. /*  pointer.                                                        */
  29. #define MINADDI2P LONG
  30.  
  31. /*  If the bytes of an integer are ordered most significant byte    */
  32. /*  byte first and then decreasing set BIGENDIAN to 1.              */
  33. #define BIGENDIAN 0
  34.  
  35. /*  If the bytes of an integer are ordered lest significant byte    */
  36. /*  byte first and then increasing set LITTLEENDIAN to 1.           */
  37. #define LITTLEENDIAN 1
  38.  
  39. /*  Note that BIGENDIAN and LITTLEENDIAN are mutually exclusive.    */
  40.  
  41. /*  If switch-statements should be generated as a sequence of       */
  42. /*  SUB,TST,BEQ ICs rather than COMPARE,BEQ ICs set this to 1.      */
  43. /*  This can yield better code on some machines.                    */
  44. #define SWITCHSUBS 1
  45.  
  46. /*  In optimizing compilation certain library memcpy/strcpy-calls   */
  47. /*  with length known at compile-time will be inlined using an      */
  48. /*  ASSIGN-IC if the size is less or equal to INLINEMEMCPY.         */
  49. /*  The type used for the ASSIGN-IC will be UNSIGNED|CHAR.          */
  50. #define INLINEMEMCPY 1024
  51.  
  52. /*  Parameters are sometimes passed in registers without __reg.     */
  53. #define HAVE_REGPARMS 1
  54.  
  55. /*  Parameters on the stack should be pushed in order rather than   */
  56. /*  in reverse order.                                               */
  57. #define ORDERED_PUSH 1
  58.  
  59. /*  Structure for reg_parm().                                       */
  60. struct reg_handle{
  61.     int nextr;
  62. };
  63.  
  64.